The present invention relates to an apparatus and a method for controlling operation of an open/close member such as a roof glass or a window glass of an automobile.
Japanese Laid-Open Patent Publication No. 2003-253957 discloses a sun roof apparatus that controls opening/closing of a roof glass of an automobile. The sun roof apparatus detects an open/closed position of the roof glass by detecting a rotation cycle of a drive motor that operates to selectively open and close the roof glass. The sun roof apparatus includes, for example, a rotation sensor that outputs a pulse signal in correspondence with rotation of the drive motor. A controller counts rises or falls of the pulse signal provided by the rotation sensor and detects the open/closed position of the roof glass in accordance with the count value. In this manner, the controller controls operation of the roof glass in correspondence with the open/closed position of the roof glass. The count value, in accordance with which the open/closed position of the roof glass is detected, is stored in a RAM of the controller as learned data that is rewritten each time the count value changes.
As is publicly known, the RAM is a volatile memory from which the data is deleted when the power supply is cut. Thus, if, for example, reset starting in which the voltage of the power supply to the controller falls to a value smaller than or equal to a predetermined level and then re-increases to a value greater than the predetermined level occurs, it is checked whether the learned data, or the count value, stored in the RAM is retained normally.
If the roof glass is operated through manipulation of a manipulating switch before the engine of the automobile is started and the engine starter motor is actuated to start the engine while the roof glass is moving, the voltage of the power supply to the controller instantly drops by a great amount to a value smaller than or equal to the predetermined level. In this case, since the voltage drop of the power supply lasts only for a short time, the data stored in the RAM is prevented from being deleted. It is thus determined that the learned data (the count value) is retained normally in the RAM in the reset starting.
However, if the waveform of the pulse signal of the rotation sensor becomes abnormal in such instant drop of the voltage of the power supply, the rises or falls of the pulse signal cannot be counted. Further, even if the waveform of the pulse signal is normal, there may be cases in which the rises or falls of the pulse signal cannot be counted or the RAM cannot be rewritten. In these cases, the count value stored in the RAM remains unchanged despite the fact that the roof glass is actually moving. This causes a difference between the actual open/closed position of the roof glass and the count value, thus bringing about a problem in control.
To solve this problem, if the reset starting occurs, original position setting (initial setting), or initializing and resetting the relationship between the actual open/closed position of the roof glass and the count value, may be performed through manipulation of the manipulating switch by the user. However, it is extremely troublesome for the user to carry out the original position setting each time the reset starting occurs.